/* **********************************************************
 * Copyright 2010 Dimitar Vangelovski
 *
 * This file is part of the Gens3 3D Engine.
 * 
 * The Gens3 3D Engine is free software; you can redistribute it and/or
 * modify it under the terms of version 2 of the GNU General Public
 * License as published by the Free Software Foundation.
 * 
 * The Gens3 3D Engine is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 * General Public License for more details.
 * 
 * You should have received a copy of the GNU General Public License
 * along with the Gens3 3D Engine; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
 * 02110-1301, USA
 * **********************************************************/


#pragma once

#include "MeshVertexNormal.h"

class CMeshFaceNormal
{
public:

	CMeshFaceNormal();
	CMeshFaceNormal(const CMeshFaceNormal &other);
	CMeshFaceNormal(int n2, float x2, float y2, float z2, CMeshVertexNormal v0, CMeshVertexNormal v1, CMeshVertexNormal v2);
	~CMeshFaceNormal();

	void			SetVertNormal(int iIndex, CMeshVertexNormal &theNormal) { m_VertNormal[iIndex] = theNormal; }
	void			SetVertIndex(int iIndex) { n = iIndex; }

	CMeshVertexNormal	GetVertNormal(int iIndex) const { return m_VertNormal[iIndex]; }
	float			GetX() const { return x; }
	float			GetY() const { return y; }
	float			GetZ() const { return z; }
	int			GetVertIndex() const { return n;}

private:
	CMeshVertexNormal	m_VertNormal[3];
	int			n;			// Face index

public: // private
	float			x, y, z;		// The face normal vector
};
